<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>方法</title>
    <script>
        var obj = Object();
        //js中是严格区分大小写的要注意
        obj.a = 'hello';
        obj.b = function () {
            console.log('你好!');
        }
        obj.b();
    </script>
</head>
<body>

</body>
</html>